<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.7"/>
<title>test: Person类 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">test
   &#160;<span id="projectnumber">1.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.8.7 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>首页</span></a></li>
      <li class="current"><a href="annotated.html"><span>类</span></a></li>
      <li><a href="files.html"><span>文件</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>类列表</span></a></li>
      <li><a href="classes.html"><span>类索引</span></a></li>
      <li><a href="inherits.html"><span>类继承关系</span></a></li>
      <li><a href="functions.html"><span>类成员</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public 成员函数</a> &#124;
<a href="class_person-members.html">所有成员列表</a>  </div>
  <div class="headertitle">
<div class="title">Person类 参考</div>  </div>
</div><!--header-->
<div class="contents">

<p>提供一个基类  
 <a href="class_person.html#details">更多...</a></p>

<p><code>#include &lt;<a class="el" href="_person_8h_source.html">Person.h</a>&gt;</code></p>
<div class="dynheader">
类 Person 继承关系图:</div>
<div class="dyncontent">
<div class="center"><img src="class_person__inherit__graph.png" border="0" usemap="#_person_inherit__map" alt="Inheritance graph"/></div>
<map name="_person_inherit__map" id="_person_inherit__map">
<area shape="rect" id="node3" href="class_student.html" title="这是一个学生类，继承于person " alt="" coords="5,80,72,107"/><area shape="rect" id="node7" href="class_worker.html" title="这是一个工人类，继承于person " alt="" coords="96,80,160,107"/><area shape="rect" id="node5" href="class_wor_stu.html" title="这是一个技工类，继承于工人类、学生类 " alt="" coords="49,155,116,181"/></map>
<center><span class="legend">[<a href="graph_legend.html">图例</a>]</span></center></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public 成员函数</h2></td></tr>
<tr class="memitem:a171b0a2efce323557ba47b3f1d74ab82"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#a171b0a2efce323557ba47b3f1d74ab82">Person</a> (char *, int, char)</td></tr>
<tr class="memdesc:a171b0a2efce323557ba47b3f1d74ab82"><td class="mdescLeft">&#160;</td><td class="mdescRight">构造函数  <a href="#a171b0a2efce323557ba47b3f1d74ab82">更多...</a><br /></td></tr>
<tr class="separator:a171b0a2efce323557ba47b3f1d74ab82"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9f4eb1c0cf8de6606312d0219de3d4ac"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#a9f4eb1c0cf8de6606312d0219de3d4ac">Person</a> (<a class="el" href="class_person.html">Person</a> &amp;)</td></tr>
<tr class="memdesc:a9f4eb1c0cf8de6606312d0219de3d4ac"><td class="mdescLeft">&#160;</td><td class="mdescRight">拷贝构造函数  <a href="#a9f4eb1c0cf8de6606312d0219de3d4ac">更多...</a><br /></td></tr>
<tr class="separator:a9f4eb1c0cf8de6606312d0219de3d4ac"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a700ffd693321c5fe6880262acf43d4da"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a700ffd693321c5fe6880262acf43d4da"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#a700ffd693321c5fe6880262acf43d4da">~Person</a> ()</td></tr>
<tr class="memdesc:a700ffd693321c5fe6880262acf43d4da"><td class="mdescLeft">&#160;</td><td class="mdescRight">析构函数 <br /></td></tr>
<tr class="separator:a700ffd693321c5fe6880262acf43d4da"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad8ca4a72903ce0d1024b6e5d565b737f"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#ad8ca4a72903ce0d1024b6e5d565b737f">SetName</a> (char *)</td></tr>
<tr class="memdesc:ad8ca4a72903ce0d1024b6e5d565b737f"><td class="mdescLeft">&#160;</td><td class="mdescRight">设置姓名  <a href="#ad8ca4a72903ce0d1024b6e5d565b737f">更多...</a><br /></td></tr>
<tr class="separator:ad8ca4a72903ce0d1024b6e5d565b737f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a350cc59b9aaa7c6b43eed8388dcf6202"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#a350cc59b9aaa7c6b43eed8388dcf6202">SetAge</a> (int age)</td></tr>
<tr class="memdesc:a350cc59b9aaa7c6b43eed8388dcf6202"><td class="mdescLeft">&#160;</td><td class="mdescRight">设置年龄  <a href="#a350cc59b9aaa7c6b43eed8388dcf6202">更多...</a><br /></td></tr>
<tr class="separator:a350cc59b9aaa7c6b43eed8388dcf6202"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9d6c89090bcad5220add863ed9811177"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#a9d6c89090bcad5220add863ed9811177">SetGender</a> (char gender)</td></tr>
<tr class="memdesc:a9d6c89090bcad5220add863ed9811177"><td class="mdescLeft">&#160;</td><td class="mdescRight">设置性别  <a href="#a9d6c89090bcad5220add863ed9811177">更多...</a><br /></td></tr>
<tr class="separator:a9d6c89090bcad5220add863ed9811177"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af723f5f4d892088e67b363705861a65b"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#af723f5f4d892088e67b363705861a65b">GetName</a> (char *)</td></tr>
<tr class="memdesc:af723f5f4d892088e67b363705861a65b"><td class="mdescLeft">&#160;</td><td class="mdescRight">获取姓名  <a href="#af723f5f4d892088e67b363705861a65b">更多...</a><br /></td></tr>
<tr class="separator:af723f5f4d892088e67b363705861a65b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a33a70635106555c76535096ed35c08e5"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#a33a70635106555c76535096ed35c08e5">GetAge</a> ()</td></tr>
<tr class="memdesc:a33a70635106555c76535096ed35c08e5"><td class="mdescLeft">&#160;</td><td class="mdescRight">获取年龄  <a href="#a33a70635106555c76535096ed35c08e5">更多...</a><br /></td></tr>
<tr class="separator:a33a70635106555c76535096ed35c08e5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:add324409f5be9424ecebbe9f59fa180f"><td class="memItemLeft" align="right" valign="top">char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#add324409f5be9424ecebbe9f59fa180f">GetGender</a> ()</td></tr>
<tr class="memdesc:add324409f5be9424ecebbe9f59fa180f"><td class="mdescLeft">&#160;</td><td class="mdescRight">获取性别  <a href="#add324409f5be9424ecebbe9f59fa180f">更多...</a><br /></td></tr>
<tr class="separator:add324409f5be9424ecebbe9f59fa180f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abf904c9cc527f79f9c9af9ca32c5759e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_person.html#abf904c9cc527f79f9c9af9ca32c5759e">Show</a> ()</td></tr>
<tr class="memdesc:abf904c9cc527f79f9c9af9ca32c5759e"><td class="mdescLeft">&#160;</td><td class="mdescRight">显示成员信息  <a href="#abf904c9cc527f79f9c9af9ca32c5759e">更多...</a><br /></td></tr>
<tr class="separator:abf904c9cc527f79f9c9af9ca32c5759e"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock"><p>提供一个基类 </p>
<p>成员函数比较简单，主要有设置姓名、设置年龄、设置性别、 读取姓名、读取年龄、读取姓名和显示此人的信息。 </p>
</div><h2 class="groupheader">构造及析构函数说明</h2>
<a class="anchor" id="a171b0a2efce323557ba47b3f1d74ab82"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Person::Person </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>age</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char&#160;</td>
          <td class="paramname"><em>gender</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>构造函数 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">name</td><td>姓名字符串 </td></tr>
    <tr><td class="paramname">age</td><td>年龄 </td></tr>
    <tr><td class="paramname">gender</td><td>性别 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>参见</dt><dd><a class="el" href="class_person.html" title="提供一个基类 ">Person</a> :: <a class="el" href="class_person.html#a9f4eb1c0cf8de6606312d0219de3d4ac" title="拷贝构造函数 ">Person(Person &amp;p)</a> </dd></dl>

</div>
</div>
<a class="anchor" id="a9f4eb1c0cf8de6606312d0219de3d4ac"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Person::Person </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_person.html">Person</a> &amp;&#160;</td>
          <td class="paramname"><em>p</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>拷贝构造函数 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">p</td><td>一个对象 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>参见</dt><dd><a class="el" href="class_person.html" title="提供一个基类 ">Person</a> :: <a class="el" href="class_person.html#a9f4eb1c0cf8de6606312d0219de3d4ac" title="拷贝构造函数 ">Person(Person &amp;p)</a> </dd></dl>

</div>
</div>
<h2 class="groupheader">成员函数说明</h2>
<a class="anchor" id="a33a70635106555c76535096ed35c08e5"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">int Person::GetAge </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>获取年龄 </p>
<dl class="section return"><dt>返回</dt><dd>年龄 </dd></dl>

</div>
</div>
<a class="anchor" id="add324409f5be9424ecebbe9f59fa180f"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">char Person::GetGender </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>获取性别 </p>
<dl class="section return"><dt>返回</dt><dd>性别 </dd></dl>

</div>
</div>
<a class="anchor" id="af723f5f4d892088e67b363705861a65b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char * Person::GetName </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>str</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>获取姓名 </p>
<p>得到姓名</p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">名字的字符串</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>想得到的名字字符串指针</dd></dl>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">str</td><td>想要得到的名字 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>想要的名字 </dd></dl>

</div>
</div>
<a class="anchor" id="a350cc59b9aaa7c6b43eed8388dcf6202"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Person::SetAge </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>age</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>设置年龄 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">年龄</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a9d6c89090bcad5220add863ed9811177"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Person::SetGender </td>
          <td>(</td>
          <td class="paramtype">char&#160;</td>
          <td class="paramname"><em>gender</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>设置性别 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">性别</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ad8ca4a72903ce0d1024b6e5d565b737f"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Person::SetName </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>name</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>设置姓名 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">名字字符串</td><td></td></tr>
    <tr><td class="paramname">name</td><td>想要设置的姓名</td></tr>
  </table>
  </dd>
</dl>
<p>如果已经有名字，先删除，然后再拷贝新名字 </p>

</div>
</div>
<a class="anchor" id="abf904c9cc527f79f9c9af9ca32c5759e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Person::Show </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>显示成员信息 </p>
<p>显示人员信息，包括 姓名、年龄、性别 （test）</p>
<p>打印成员的信息，格式为 "Name:   Age:   Gender:   " </p>

</div>
</div>
<hr/>该类的文档由以下文件生成:<ul>
<li>TEST/<a class="el" href="_person_8h_source.html">Person.h</a></li>
<li>TEST/<a class="el" href="_person_8cpp.html">Person.cpp</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
生成于 2014年 十二月 29日 星期一 19:28:15 , 为 test使用  &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.7
</small></address>
</body>
</html>
